             package com.java.diagnostics.visualizer.recommender;
             
             import com.java.diagnostics.visualizer.data.AggregateData;
             import com.java.diagnostics.visualizer.data.StructuredData;
             import com.java.diagnostics.visualizer.recommender.util.RecommendationLabels;
             import java.text.MessageFormat;
             import java.util.Collection;
             import java.util.Iterator;
             import java.util.Map;
             
             public class AppendCommandLine
               extends RecommendationBase
               implements Recommendation
             {
               public void recommend(AggregateData data)
               {
                 StructuredData commandLine = data.getStructuredData("command.line");
                 if (commandLine == null) {
                   return;
                 }
                 Map commandLines = commandLine.getContents();
                 StringBuffer recommendation = new StringBuffer();
                 if (commandLines.size() > 0) {
                   Iterator commands = commandLines.values().iterator();
                   StringBuffer line = new StringBuffer();
                   while (commands.hasNext()) {
                     line.append(commands.next());
                     if (commands.hasNext()) {
                       line.append(" ");
                     }
                   }
                   
                   recommendation.append(MessageFormat.format(
                     RecommendationLabels.COMMAND_LINE, 
                     new String[] { line.toString() }));
                 }
                 
                 addComment(data, recommendation.toString());
               }
             }


